BUSI 721, Fall 2022
JGSB, Rice University
Kerry Back
Assume \(r_s=r_b=r_f\) (risk-free rate).
Set \(x_f = x_s - x_b\).
portfolio expected return is \(x_f r_f + w^\top \bar{r}\).
The accounting identify \(x_s + \sum_{i=1}^n w_i = 1 + x_b\) implies \(x_f\) is 1 minus sum of \(w_i\) (which is \(w^\top 1_n\)) so portfolio expected return is
\[r_f + w^\top (\bar{r}-r_f1_n)\]
\[r_f + w^\top (\bar{r}-r_f1_n)\]
subject to
\[r_f + w^\top (\bar{r}-r_f1_n) = \bar{r}_{\text{targ}}\]
\[\sum_{i=1}^n w_i^2\sigma_i^2 + 2 \sum_{i=1}^n \sum_{j=i+1}^n w_iw_j\sigma_{ij}\]
\[w_i^2\sigma_i^2 + 2 \sum_{j \neq i} w_iw_j\sigma_{ij}\]
\[2 \sum_{j=1}^n w_j \sigma_{ij}\]
Equal benefit-cost ratios means \((\bar{r}_i-r_f)/C_i^\top w =k\) for all \(i\).
Rearrange: \(k C_i^\top w = \bar{r}_i - r_f\)
Stack: \(k C w = \bar{r} - r_f 1_n\)
Solve:
\[w = (1/k)C^{-1}(\bar{r}-r_f1_n)\]
\[r_f + \frac{1}{k}(\bar{r}-r_f1_n)^\top C^{-1}(\bar{r}-r_f1_n)\]
\[k = \frac{\bar{r}_{\text{targ}}-r_f}{(\bar{r}-r_f1_n)^\top C^{-1}(\bar{r}-r_f1_n)}\]
import numpy as np
rf = 0.02
mn1, mn2, mn3 = 0.06, 0.08, 0.10
sd1, sd2, sd3 = 0.1, 0.15, 0.12
corr12, corr13, corr23 = 0.5, 0.7, 0.6
targ = 0.09
S = np.diag([sd1, sd2, sd3])
R = np.identity(3)
R[0, 1] = R[1, 0] = corr12
R[0, 2] = R[2, 0] = corr13
R[1, 2] = R[2, 1] = corr23
C = S @ R @ S
rprem = np.array([mn1, mn2, mn3]) - rf
Model
GMV = Global Minimum Variance portfolio of risky assets only
Can find with calculus
Two risky assets:
\[\small \frac{w_{A}}{w_{B}}=\frac{\sigma^2_{B}-\rho\sigma_{A}\sigma_{B}}{\sigma^2_{A}-\rho\sigma_{A}\sigma_{B}}\]
Examples:
\(\text{n}\) risky assets: vector of weights has same inner product with each column of covariance matrix (\(n-1\) equations)
\[\small \frac{w^{⊤}Cov_{i}}{w^{⊤}Cov_{j}}=1\]
and \(\small \sum w_{i}=1\).
import numpy as np
# standard deviations
sds = np.array([0.15, 0.25, 0.35])
S = np.diag(sds)
# correlations
r12 = 0.15
r13 = 0.6
r23 = 0.3
R = np.identity(3)
R[0, 1] = R[1, 0] = r12
R[0, 2] = R[2, 0] = r13
R[1, 2] = R[2, 1] = r23
# covariance matrix
C = S @ R @ S
# GMV portfolio
w = np.linalg.solve(C, np.ones(3))
w = w / np.sum(w)\(w_{1}\)=0.89 \(w_{2}\)=0.25 \(w_{3}\)=-0.14
For any target expected return, find the minimum variance portfolio.
Set of (std dev, mean) pairs is called the mean-variance frontier (of risky assets).
Similar optimization problem to GMV portfolio.
Combining risk-free asset with any portfolio
\(\rightarrow\) line from \(r_{f}\) through the (std dev, mean) of the portfolio.
Slope of the line is the Sharpe ratio.
Goal is to go northwest in the diagram (higher Sharpe ratio).
Line with highest Sharpe ratio is tangent to the risky-asset-only frontier.
As with the GMV portfolio, we can represent the tangency portfolio using calculus.
The inner product of the tangency portfolio with each column of the covariance matrix is proportional to the asset’s risk premium:
\[\frac{w^{⊤}Cov_{i}}{w^{⊤}Cov_{j}}=\frac{\bar{r}_{i}-r_{f}}{\bar{r}_{j}-r_{f}}\]
and \(\sum w_{i}=1.\)
import numpy as np
# standard deviations
sds = np.array([0.15, 0.25, 0.35])
S = np.diag(sds)
# correlations
r12 = 0.15
r13 = 0.6
r23 = 0.3
R = np.identity(3)
R[0, 1] = R[1, 0] = r12
R[0, 2] = R[2, 0] = r13
R[1, 2] = R[2, 1] = r23
# covariance matrix
C = S @ R @ S
# GMV portfolio
w = np.linalg.solve(C, np.ones(3))
w = w / np.sum(w)\(w_{1}\)=0.37 \(w_{2}\)=0.58 \(w_{3}\)=0.05